package com.woniuxy02;

import java.io.FileReader;
import java.io.FileWriter;
import java.io.IOException;

public class Test05 {

    public static void main(String[] args) throws IOException {
        FileReader fr=new FileReader("d:\\aaa\\a.png");
        FileWriter fw=new FileWriter("d:\\aaa\\b.png");
        char[] chars=new char[1024];
        int length;
        while((length=fr.read(chars))!=-1){
            fw.write(chars,0,length);
            fw.flush();
        }
        fw.close();
        fr.close();
    }

}
